package com.kob.backend.controller.shop;

import com.kob.backend.mapper.ShopMapper;
import com.kob.backend.pojo.product;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;
@RestController
public class ShopAllproductsGetController {
    @Autowired
    private ShopMapper shopMapper;
    @GetMapping("/shopproduct/get/")
    public List<product>getallshopproduct(@RequestParam Map<String,String>map)
    {
        Integer shopid = Integer.parseInt(map.get("shopid"));
        return shopMapper.getallshopproducts(shopid);
    }
}
